package me.firstapp.spi.shop;

import java.util.Map;

import me.firstapp.common.json.PageObject;
import me.firstapp.common.json.SingleObject;
import me.firstapp.common.module.bbs.JsonPointAccount;
import me.firstapp.common.module.bbs.JsonPointAccountTrace;

public interface PointService {

	/**
	 * 调用查询用户积分账户接口
	 * 
	 * @param memberId
	 * @return
	 */
	SingleObject<JsonPointAccount> findPointAccount(Long memberId);

	/**
	 * 调用分页查询用户积分流水接口
	 * 
	 * @param pageNo
	 * @param pageSize
	 * @param memberId
	 * @return
	 */
	PageObject<JsonPointAccountTrace> findPointAccountTraces(Integer pageNo, Integer pageSize, Long memberId);

	/**
	 * 调用修改用户积分支付密码接口
	 * 
	 * @param memberId
	 * @param oldPassword
	 * @param newPassword
	 * @param code
	 * @return
	 */
	SingleObject<Object> alterPayPassword(Long memberId, String oldPassword, String newPassword, String code);

	/**
	 * 调用积分充值接口
	 * 
	 * @param memberId
	 * @param cardNo
	 * @param password
	 * @param payPassword
	 * @param code
	 * @return
	 */
	SingleObject<JsonPointAccount> rechargePoint(Long memberId, String cardNo, String password, String payPassword,
			String code);

	/**
	 * 调用分页查询用户积分流水接口
	 * 
	 * @param memberId
	 * @param pageNo
	 * @param pageSize
	 * @param searchParams
	 * @param sortParam
	 * @param sortType
	 * @param startTime
	 * @param endTime
	 * @return
	 */
	PageObject<JsonPointAccountTrace> findPointAccountTracePageByParams(Long memberId, Integer pageNo, Integer pageSize,
			Map<String, Object> searchParams, String sortParam, String sortType, Long startTime, Long endTime);
}
